package com.atguigu.i_test;

public class Demo {
    public static void main(String[] args) {
        //创建子类对象
        PingPongPlayer ppp = new PingPongPlayer("马龙", 20);
        ppp.eat("全鸭宴");
        ppp.study();
        ppp.sleep();
        System.out.println("-------------------------------");
        PingPongCoach ppc = new PingPongCoach("刘国梁", 50);
        ppc.eat("满汉全席");
        ppc.teach();
        ppc.sleep();
        System.out.println("-------------------------------");
        BasketBallPlayer bbp = new BasketBallPlayer("王哲林", 18);
        bbp.eat("欧力给");
        bbp.study();
        bbp.sleep();
        bbp.learnEnglish();
        System.out.println("-------------------------------");
        BasketBallCoach bbc = new BasketBallCoach("姚明", 40);
        bbc.eat("汉堡包");
        bbc.teach();
        bbc.sleep();
        bbc.learnEnglish();
    }
}
